﻿<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="edge">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1.0,user-scalable=0">
    <meta content="telephone=no" name="format-detection" />
    <meta name="description" content="">
	<meta name="keywords" content="">
    <title>知识库-搜索</title>
    <link rel="stylesheet" type="text/css" href="css/reset.css">
    <link rel="stylesheet" type="text/css" href="css/global.css">
    <link rel="stylesheet" type="text/css" href="css/media.css">
</head>
<body id="app">
	<!-- 头部 -->
    <!-- <header class="header1">
        <a href="javascript:history.go(-1);" title="返回" class="icon back"></a>
        <div class="clearfix search-box">
		    
           <input type="button" class="fl search-btn" @click="search();">
		    <input type="text" id="searchword" class="search-txt" placeholder="搜索" value="" maxlength="30">
		</div>
    </header> -->

    <header class="header" id="header1">
        <a href="circleSearch.html" title="返回" class="icon back"></a>
        <div class="clearfix search-box" onclick="show();">
            <input type="button" class="fl search-btn" >
            <input type="text" id="searchword2"  class="search-txt"  placeholder="搜索" value="" maxlength="30">
        </div>
    </header>
    
    <header class="header dn" id="header2">
        <div class="clearfix search-box searchWhite">
            <input type="button" class="fl search-btn" @click="search();">
            <input type="text" id="searchword" class="search-txt" placeholder="搜索" value="" maxlength="30">
        </div>
        <a href="javascript:void(0);" title="取消" class="text j_cancle">取消</a>
    </header>



    <template v-if="addShow==true">
        <div class="cateBoxBg" ></div>
    </template>
    
	<!-- 搜索结果 -->
	<section class="padT23 ">
		<!-- tab -->
        <ul class="clearfix tabUl quesTab dn">
        	<li class="on">文档</li>
        	<li>回答</li>
        	<li>话题</li>
        </ul>
        <div>
            <!-- 推荐 -->
            <ul class="tabCont quesCont askCont" >
                <li class="answer" v-for="info in data">
                    <a href="javascript:;" @click="tocircleDetail(info.id);">
                        <div class="clearfix line95">
                            <img :src="info.headPic" class="fl borderRadius wh45">
                            <span class="db fl marL24 font20 color72">{{ info.author }}<em class="colorB">({{ info.level }})</em></span>
                            <span class="fr font20 colorb6">{{ info.date }}</span>
                        </div>
                        <h3 class="font26 color22 titles">{{ info.title }}</h3>
                        <span class="db font26 color21 ell">{{ info.content }}</span>
                        <div class="clearfix marT24 askImgBox">
                            <span class="db fl j_6 askImg" v-for='(index, item) in info.contentPicture' track-by="$index"><img data-src="{{item}}" src="images/imgload.gif" alt="" class="loadImg"></span>
                            <em class="imgNum">8</em>
                        </div>
                        <div class="clearfix">
                            <template v-if="info.isTop == 1">
                                <span class="fl zdIcon"></span>
                            </template>
                            <!-- 带精字图标的话题 -->
                            <template v-if="info.isEssence == 1">
                                <span class="fl jIcon"></span>
                            </template>
                            <span class="fr comIcon">{{ info.commentCount }}</span>
                            <span class="fr view">{{ info.readCount }}</span>
                            <!-- 如果是已点赞的，则有class="on" -->
                            <span class="fr likeIcon" v-bind:class="{'on':info.likeCount>0}">{{ info.likeCount }}</span>
                        </div>
                    </a>
                </li>
            </ul>

        </div>
	</section>

    <!-- 搜索无结果 -->
    <section class="padT23 searchNone dn" >
        <img src="images/searchNone.png" class="none">
        <span class="db font24 color21 desc">没有“{{keyWork}}”的搜索结果</span>
    </section>
	
	<script type="text/javascript" src="js/lib/jquery.min.js"></script>
    <script type="text/javascript" src="js/lib/vue.js"></script>
    <script type="text/javascript" src="js/lib/global.js"></script>
    <script type="text/javascript" src="js/app.js"></script>
    <script type="text/javascript" src="js/scrollbar.js"></script>
    <script type="text/javascript" src="js/lib/common.js"></script>
    <script type="text/javascript" src="js/circleSearchResult.js"></script>

    <script type="text/javascript">
        $('#searchword').bind('keypress',function(event){
            if(event.keyCode == "13")    {
                info.search();
            }
        });
        function show(){
            info.addShow = true;
            $("#header1").hide();
            $('#header2,.cateBoxBg').show();
            $("#searchword").focus();
        }
        $('.j_cancle').bind('click',function(){
            $("#header2,.cateBoxBg").hide();
            $("#header1").show();
        });

    </script>


</body>
</html>